iT邦幫忙

0

全端基礎-前端(1).calendar(html架構)

  • 分享至 

  • xImage
  •  

header.php

<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Calendar demo</title>
	
	<link rel="stylesheet" href="css/bootstrap.min.css">
	<link rel="stylesheet" href="css/main.css">
	
	<script src="js/jquery-3.2.1.min.js"></script>
	<script src="js/handlebars-v4.0.11.js"></script>
	<script src="js/action.js"></script>
</head>
<body>

footer.php

</body>
</html>

index.php

<?php include('header.php'); ?>
<?php include('data.php'); ?>

<div id="calender">
    <div id="header">
        <?= date('Y') ?>/<?= date('m') ?>
    </div>
    <div id="days" class="clearfix">
        <div class="day">SUN</div>
        <div class="day">MON</div>
        <div class="day">TUE</div>
        <div class="day">WED</div>
        <div class="day">THU</div>
        <div class="day">FRI</div>
        <div class="day">SAT</div>
    </div>

    <div id="dates" class="clearfix">
        <?php foreach($dates as $key => $date): ?>
            <div class="date-block>
                <div class="date"><?= $date ?></div>
                <div class="events">
        
                </div>
            </div>
        <?php endforeach ?>
    </div>
</div>

<script id="todo-list-item-template" type="text/x-handlebars-template">
<li data-id="{{id}}" class="{{#if is_complete}}complete{{/if}}">
    <div class="checkbox"></div>
    <div class="content">{{content}}</div>
    <div class="actions">
        <div class="delete">
            x
        </div>
    </div>
</li>
</script>
<?php include('footer.php'); ?>

data.php

<?php
// include('../db.php');

// try{
//     $pdo = new PDO("mysql:host=$db[host];dbname=$db[dbname];port=$db[port];charset=$db[charset]",$db['username'],$db['password']);
// }catch(PDOException $e){
//     echo "Database connection failed.";
//     exit;
// }

$dates = [];
for($i=1; $i<=31; $i++){
   $dates[] = $i;
}
$dates[] = null;
$dates[] = null;
$dates[] = null;
$dates[] = null;
?>

圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友留言

立即登入留言